<!--
 * @FileDescription 端子信息
 * @Author lz
 * @Date 20230612 15:21:31
 * @LastEditors lz
 * @LastEditTime 20230612 15:21:31
-->
<template>
  <div class="Dia_wp">
    <div class="Popup">
      <div class="titBox">
        端子信息 - {{ HomeContent.Default.TiData.value.Name }}
        <close-outlined class="cancel" @click="cancel" />
      </div>
      <div class="Ticontent">
        <div class="TCol_l">
          <!-- <img src="/public/pictures/U06.png"> -->
          <!-- 前面不要加public就可以找到路径了 错误示范：<img :src="`/public/pictures/${HomeContent.Default.TiData.value.Code}.png`"> -->
          <!-- <img :src="`/pictures/${HomeContent.Default.TiData.value.Code}.png`" /> -->
          <img :src="`/res/端子信息/${HomeContent.Default.TiData.value.Code}.png`" />
          <div class="description">实现外部电源与车辆电池间的电能转换和适配，如将不同电压和频率的交流电转为适合电池的直流电，控制充电流和电压，确保安全高效充电。
            负责电能合理分配，依车辆不同系统用电需求精准送能，保障部件正常运行。</div>
        </div>
        <div class="TCol_r">
          <div class="cr_r">
            <div class="TCL_l" v-for="(item, index) in HomeContent.Default.TiData.value.Terminals" :key="index">
              <div class="SerialNumber">{{ item.Id }}</div>
              <div class="TCL_txt">{{ item.Description }}</div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script setup lang="ts">
import { CloseOutlined } from "@ant-design/icons-vue";
import { ClientMessage } from "@runtime/generate/message/ClientMessage";
import WebSocketComponent from "@runtime/module/WebSocket/WebSocketComponent";
import { Item } from "ant-design-vue/lib/menu";
import { onMounted, reactive } from "vue";
import HomeContent from "../HomeContent";
import MessageCode from "../MessageCode";
const state = reactive({
  tabList: <any>[],
  DetailedData: <any>[],
});
//关闭
function cancel() {
  HomeContent.Default.TiType.value = false;
}
onMounted(async () => { });
</script>

<style scoped>
.description {
  width: 460px;
  height: 100px;
  position: absolute;
  bottom: 79px;
  /* bottom: 122px; */
  left: 63px;
  font-size: 16px;
  color: #000;
  text-indent: 2em;
}

.Dia_wp {
  width: 100%;
  height: 100%;
  background-color: rgb(0, 0, 0, 0.3);
  position: relative;
}

.Popup {
  width: 1440px;
  height: 814px;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -60%);
  background: #ffffff;
  border-radius: 16px 16px 16px 16px;
}

.titBox {
  height: 54px;
  font-size: 36px;
  font-weight: 600;
  color: #000000;
  line-height: 42px;
  margin-top: 30px;
  margin-left: 40px;
}

.cancel {
  font-size: 28px;
  font-weight: 600;
  float: right;
  margin-top: 4px;
  margin-right: 30px;
}

.Ticontent {
  overflow: hidden;
  margin-top: 24px;
  margin-left: 40px;
}

.TCol_l {
  float: left;
  width: 500px;
  height: 660px;
  border-radius: 12px 12px 12px 12px;
  opacity: 1;
  border: 1px solid #e1e3e8;
  /* overflow-y: auto; */
  text-align: center;
}
.TCol_l > img {
  margin-top: 10px;
}
.TCol_r {
  float: left;
  width: 820px;
  height: 660px;
  border-radius: 12px 12px 12px 12px;
  opacity: 1;
  border: 1px solid #e1e3e8;
  margin-left: 40px;
  overflow-y: auto;
  padding-bottom: 10px;
}

.TCol_r::-webkit-scrollbar {
  width: 6px;
  height: 1px;
}

.TCol_r::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background: #dfe1e8;
}

.TCol_r::-webkit-scrollbar-track {
  border-radius: 10px;
  background: #f8f8f8;
}

.cr_r {
  margin-top: 24px;
  margin-left: 36px;
}

.TCL_l {
  width: 748px;
  height: 72px;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
}

.SerialNumber {
  width: 20px;
  height: 20px;
  background: #9bfb4e;
  border-radius: 10px 10px 10px 10px;
  opacity: 1;
  color: #000;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  line-height: 20px;
  margin-left: 18px;
  margin-right: 18px;
}

.TCL_txt {
  font-size: 16px;
  color: #202020;
}
</style>
